#ifndef SHOP_H
#define SHOP_H

class Field;
class ShopItem;

class Shop
{
    public:
        static const int SIZE = 1;

        Shop( Field* f, int money_ = 0 )
        :money(money_), field(f)
        {
            initialize();
        }

        ~Shop() {
            delete[] items;
        }

        int getMoney() const { return money; }
        Field* getField() const { return field; }
        ShopItem* getItem( int i ) const;

        void setMoney( int i ) { money = i; }
        void addMoney( int i );
        bool spendMoney( int i );
    protected:
    private:
        // amount of money
      int money;
        // used for item's  effects
      Field* field;

      ShopItem* items[SIZE];
        // fills items
      void initialize();
};

#endif // SHOP_H
